package com.dao.impl;

import org.springframework.stereotype.Repository;

import com.dao.OrderDao;
import com.entity.DangOrder;
@Repository
public class OrderDaoImpl extends BaseDaoImpl implements OrderDao {

	@Override
	public int addOrder(DangOrder order) {
		getSession().save(order);
		return order.getId();
	}

	@Override
	public DangOrder getOrder(int id) {
		return (DangOrder) getSession().get(DangOrder.class, id);
	}

}
